home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 40
/
Aminet 40 (2000)(Schatztruhe)[!][Dec 2000].iso
/
Aminet
/
comm
/
irc
/
KuangEleven3Gm.lha
/
Kuang Eleven 3
/
Rexx
/
CTCP
/
autogetsounds.amirx
next >
Wrap
Text File
|
1998-05-09
|
1KB
|
35 lines
/* $VER: autogetsounds.amirx 1.0 (9.5.98) Kuang Eleven Plugin : autoget missing sounds
** Requires AmIRC 2!
**
** ctcp=0 Request sound via !nick soundfile (PUBLIC CHANNEL!)
** ctcp=1 Request sound via CTCP GETSOUND
**
** autoget=0 Do not autoget DCC of requested sounds.
** autoget=1 autoget DCC of requested sounds.
** Note : this is a K¹¹ 2.8+ Feature ONLY
*/
ctcp=1
autoget=1
/* Do not mess with stuff below unless you know what you are doing */
options results
parse arg ':'prefix' 'type' 'channel' :'text
parse var prefix nick'!'user'@'host
div='01'x
parse var text (div) command file . (div)
if upper(command)~='SOUND' then exit
if file~==compress(file,'/:`"*') then exit
"GETCTCPSOUNDDIR"
if ~exists(prsprg(result)||file) then do
if ctcp=0 then 'SAY !'nick file 'K¹¹ AutoRequest'
else 'QueueRAW PRIVMSG' nick ':'div||'GETSOUND' file||div
"ECHO P="d2c(27)"b«GetSound» Requested" d2c(2)file||d2c(2) "from" d2c(2)||nick
if autoget then setclip('st_autoget',strip(getclip('st_autoget') upper(file)))
end
exit
prsprg:PROCEDURE
X=addpart(ARG(1),'')
"GETPROGDIR"
Y=RESULT
IF UPPER(LEFT(X,8))='PROGDIR:' THEN RETURN addpart(Y,'')||SUBSTR(X,9)
RETURN X